<?php get_header(); ?>

<script>
    <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
        location.href = "<?php echo home_url(); ?>?post=<?php echo the_ID(); ?>";
    <?php endwhile; endif; ?>
</script>

<?php get_footer(); ?>